package com.itheima.restkeeper.web;

/**
 * @author ShenMin
 * @date 2021/9/1 10:21
 * @description
 */
public class test {
    public static void main(String[] args) {
//        String str1 = "hello";
//        String str2 = "he" + new String("llo");
//        System.err.println(str1==str2);
//        System.err.println(str1.equals(str2));
         A a = new B();
        System.out.println("==========");
         a = new B();
    }
}

class A {
    static {
        System.out.println("a1");
    }

    public A(){
        System.out.println("a2");
    }
}

class B extends A{
    static {
        System.out.println("b1");
    }
    public B(){
        System.out.println("b2");
    }
}

